FROM python:3.6.8
RUN sed -i 's#http://deb.debian.org#http://mirrors.aliyun.com/#' /etc/apt/sources.list
RUN apt-get update --fix-missing && apt-get install -y nginx --fix-missing && apt-get install -y uwsgi --fix-missing
ENV PYTHONUMBUFFERED 1
RUN pip install --upgrade pip && pip install uwsgi
RUN mkdir -p /deploy/
WORKDIR /deploy/
ADD . XTools2/
WORKDIR /etc/nginx
CMD ["nginx"]
EXPOSE 80
CMD ["/bin/sh","uwsgi --ini uwsgi.ini"]